package cn.com.miaoto.service;

import cn.com.miaoto.base.common.BaseService;
import cn.com.miaoto.model.Menu;
import cn.com.miaoto.mysql.MenuMapper;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.List;

/**
 * Created by guo.chen on 2018/11/9.
 */
@Service
public class MenuService extends BaseService<Menu> {

    @Resource
    private MenuMapper menuMapper;

    public List<Menu> selectMenusByRoleId(Integer roleid) {
        return menuMapper.selectMenusByRoleId(roleid);
    }

    public List<Menu> selectByParentIdAndRoleId(HashMap<String, Object> paraMap) {
        return menuMapper.selectByParentIdAndRoleId(paraMap);
    }
}
